<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>MCSManager 文件列表</title>
    <style>
        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }

        body {
            font-family: 'Microsoft YaHei', sans-serif;
            background: #f5f6fa;
            padding: 20px;
            color: #2c3e50;
        }

        .container {
            max-width: 800px;
            margin: 0 auto;
            background: white;
            border-radius: 10px;
            box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
            padding: 20px;
        }

        .header {
            text-align: center;
            padding-bottom: 15px;
            margin-bottom: 20px;
            border-bottom: 1px solid #eee;
        }

        .header h1 {
            color: #34495e;
            font-size: 20px;
            margin-bottom: 8px;
        }

        .current-path {
            color: #7f8c8d;
            font-size: 14px;
            word-break: break-all;
        }

        .file-list {
            display: grid;
            gap: 10px;
        }

        .file-item {
            display: grid;
            grid-template-columns: auto 1fr auto auto;
            align-items: center;
            gap: 12px;
            padding: 10px;
            background: #f8f9fa;
            border-radius: 6px;
        }

        .file-icon {
            width: 24px;
            height: 24px;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 16px;
        }

        .file-name {
            font-size: 14px;
            color: #34495e;
            word-break: break-all;
        }

        .file-size {
            font-size: 12px;
            color: #7f8c8d;
            text-align: right;
        }

        .file-time {
            font-size: 12px;
            color: #7f8c8d;
            text-align: right;
            min-width: 150px;
        }

        .footer {
            margin-top: 20px;
            text-align: center;
            color: #95a5a6;
            font-size: 12px;
        }

        .empty-message {
            text-align: center;
            padding: 40px 0;
            color: #7f8c8d;
            font-size: 14px;
            background: #f8f9fa;
            border-radius: 6px;
            margin: 20px 0;
        }

        .path-info {
            font-size: 14px;
            color: #666;
            margin-bottom: 5px;
        }

        .total-info {
            font-size: 14px;
            color: #666;
        }

        .file-list {
            display: flex;
            flex-direction: column;
            gap: 10px;
        }

        .file-item {
            padding: 10px;
            background: #f9f9f9;
            border-radius: 5px;
            font-size: 14px;
        }

        .file-name {
            color: #333;
            font-weight: bold;
            margin-bottom: 5px;
        }

        .file-info {
            color: #666;
            font-size: 12px;
            display: flex;
            gap: 15px;
        }

        .pagination {
            margin-top: 15px;
            text-align: right;
            color: #666;
            font-size: 12px;
        }
    </style>
</head>
<body>
    <div class="container">
        <div class="header">
            <h1>MCSManager 文件列表</h1>
            <div class="current-path">当前路径: {{currentPath}}</div>
            <div class="total-info">共 {{ total }} 个文件/文件夹 (第{{ page + 1 }}页，每页{{ pageSize }}个)</div>
        </div>

        {{if files.length > 0}}
        <div class="file-list">
            {{each files file}}
            <div class="file-item">
                <div class="file-icon">{{file.isDirectory ? '📁' : '📄'}}</div>
                <div class="file-name">{{file.name}}</div>
                <div class="file-size">{{file.isDirectory ? '-' : formatSize(file.size)}}</div>
                <div class="file-time">{{formatTime(file.time)}}</div>
            </div>
            {{/each}}
        </div>
        {{else}}
        <div class="empty-message">
            当前目录为空
        </div>
        {{/if}}

        <div class="footer">
            Generated by Yunzai-Bot MCSManager Plugin
        </div>
    </div>
</body>
</html> 